//
//  TextContentCell.m
//  ZYHome
//
//  Created by Teplot_03 on 16/7/6.
//  Copyright © 2016年 Teplot_01. All rights reserved.
//

#import "TextContentCell.h"
#import "BaseContentCell.h"

@interface TextContentCell ()

/**
 *  左边的删除按钮
 */
//@property (nonatomic, strong) UIButton *deleteBtn;

/**
 *  显示文字的label
 */
@property (nonatomic, strong) UILabel *textL;

@end

@implementation TextContentCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        
    }
    return self;
}

- (void)setup {
    [super setup];
    [self.contentView addSubview:self.textL];
    
    
    _textL.sd_layout.leftSpaceToView(self.deleteBtn,10)
    .rightSpaceToView(self.contentView,30)
    .topSpaceToView(self.contentView,10)
    .bottomSpaceToView(self.contentView,10);
    
}

#pragma mark - lazy load
/**
 *  topBtn
 deleteBtn
 textL
 */

- (UILabel *)textL {
    if (!_textL) {
        _textL = [UILabel new];
        _textL.text = @"添加一段文字";
        _textL.textColor = grayTextColor;
        _textL.numberOfLines = 0;
        _textL.textAlignment = NSTextAlignmentLeft;
//#warning 这里增加一个label内容靠上显示
    }
    return _textL;
}

- (void)setText:(NSString *)text {
    _text = text;
    self.textL.text = text;
}

@end
